package com.fowo.api.model.supplier.msg;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.format.DateTimeFormat;
import com.alibaba.excel.annotation.write.style.ContentStyle;
import com.alibaba.excel.enums.poi.HorizontalAlignmentEnum;
import javax.validation.constraints.*;
import lombok.Getter;
import lombok.Setter;

/** 供应商通知 导入导出辅助模型 */
@Getter
@Setter
public class SupplierMsgExcelPo {

  @ExcelProperty(value = "表单id")
  private Long formId;

  @NotBlank(message = "消息标题不能为空")
  @Size(max = 1024, message = "消息标题长度不能超过20")
  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "*消息标题")
  private String title;

  @NotBlank(message = "消息内容不能为空")
  @Size(max = 50, message = "消息内容长度不能超过20")
  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "*消息内容")
  private String content;

  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "接收人员")
  private String toUserName;

  @ExcelIgnore
  @ExcelProperty(value = "接收人员")
  private Long toUser;

  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "接收角色")
  private String toRoleRoleName;

  @ExcelIgnore
  @ExcelProperty(value = "接收角色")
  private Long toRole;

  @DateTimeFormat("yyyy年MM月dd日HH:mm:ss")
  @ExcelProperty(value = "失效时间")
  private java.util.Date endTime;

  @NotBlank(message = "提醒方式不能为空")
  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "*提醒方式")
  private String remindType;

  @NotBlank(message = "状态不能为空")
  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "*状态")
  private String status;

  @Size(max = 50, message = "备注长度不能超过20")
  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "备注")
  private String remark;

  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "流程编码")
  private String enCode;
}
